﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="CityEdit.aspx.cs" Inherits="Card.Manager.CityEdit" %>
<%@ Register Src="Controls/UserPicker.ascx" TagName="UserPicker" TagPrefix="uc1" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>城市站编辑</title>
    <link href="Css/Style.css" rel="Stylesheet" type="text/css" />
</head>
<body>
    <form id="form1" runat="server">
    <table class="TB">
        <tr>
            <td class="TD_Input_Text">
                代码
            </td>
            <td class="TD_Input">
                <asp:TextBox ID="txtCode" runat="server" MaxLength="50"></asp:TextBox>
            </td>
            <td class="TD_Input_Text">
                名称
            </td>
            <td class="TD_Input">
                <asp:TextBox ID="txtName" runat="server" MaxLength="50"></asp:TextBox>
            </td>
        </tr>
        <tr>
            <td class="TD_Input_Text">
                网址
            </td>
            <td class="TD_Input">
                <asp:TextBox ID="txtURL" runat="server" MaxLength="500"></asp:TextBox>
            </td>
            <td class="TD_Input_Text">
                字母
            </td>
            <td class="TD_Input">
                <asp:DropDownList ID="dropKey" runat="server">
                    <asp:ListItem Value="A">A</asp:ListItem>
                    <asp:ListItem Value="B">B</asp:ListItem>
                    <asp:ListItem Value="C">C</asp:ListItem>
                    <asp:ListItem Value="D">D</asp:ListItem>
                    <asp:ListItem Value="E">E</asp:ListItem>
                    <asp:ListItem Value="F">F</asp:ListItem>
                    <asp:ListItem Value="G">G</asp:ListItem>
                    <asp:ListItem Value="H">H</asp:ListItem>
                    <asp:ListItem Value="J">J</asp:ListItem>
                    <asp:ListItem Value="K">A</asp:ListItem>
                    <asp:ListItem Value="L">L</asp:ListItem>
                    <asp:ListItem Value="M">M</asp:ListItem>
                    <asp:ListItem Value="N">N</asp:ListItem>
                    <asp:ListItem Value="P">P</asp:ListItem>
                    <asp:ListItem Value="Q">Q</asp:ListItem>
                    <asp:ListItem Value="R">R</asp:ListItem>
                    <asp:ListItem Value="S">S</asp:ListItem>
                    <asp:ListItem Value="T">T</asp:ListItem>
                    <asp:ListItem Value="W">W</asp:ListItem>
                    <asp:ListItem Value="X">X</asp:ListItem>
                    <asp:ListItem Value="Y">Y</asp:ListItem>
                    <asp:ListItem Value="Z">Z</asp:ListItem>
                </asp:DropDownList>
            </td>
        </tr>
        <tr>
            <td class="TD_Input_Text">
                是否开通
            </td>
            <td class="TD_Input">
                <asp:DropDownList ID="dropIsActive" runat="server">
                    <asp:ListItem Value="N">不开通(N)</asp:ListItem>
                    <asp:ListItem Value="Y">开通(Y)</asp:ListItem>
                </asp:DropDownList>
            </td>
            <td class="TD_Input_Text">
                排序
            </td>
            <td class="TD_Input">
                <asp:TextBox ID="txtSort" runat="server" Text="0" MaxLength="5"></asp:TextBox>
            </td>
        </tr>
        <tr>
            <td class="TD_Input_Text">
                省份
            </td>
            <td class="TD_Input">
                <asp:DropDownList ID="dropProvince" runat="server">
                </asp:DropDownList>
            </td>
        </tr>
        <tr id="trManager" runat="server" visible="false">
            <td class="TD_Input_Text">
                管理员<br /><uc1:UserPicker ID="userPicker" Text="添加管理员" runat="server" AutoPostBack="true" />
            </td>
            <td class="TD_Input" colspan="3">
                <asp:Repeater ID="rptManager"   runat="server" 
                    onitemcommand="rptManager_ItemCommand">
                    <HeaderTemplate>
                        <table class="TB">
                            <tr class="TB_Header">
                                <td>
                                    UserID
                                </td>
                                <td>
                                    工号
                                </td>
                                <td>
                                    用户名
                                </td>
                                <td>
                                    真实姓名
                                </td>
                                <td>                                    
                                </td>
                            </tr>
                    </HeaderTemplate>
                    <ItemTemplate>
                        <tr class="TB_Item">
                            <td><%# Eval("USER_ID") %></td>
                            <td><%# Eval("EMPLOYEE_NUMBER")%></td>
                            <td><%# Eval("USER_NAME")%></td>
                            <td><%# Eval("REAL_NAME")%></td>
                            <td>
                                <asp:LinkButton ID="btnDelete" CommandName="DELETE" CommandArgument='<%#Eval("USER_ID") %>' runat="server">删除</asp:LinkButton>
                            </td>
                        </tr>
                    </ItemTemplate>
                    <AlternatingItemTemplate>
                    <tr class=" TB_Alter">
                            <td><%# Eval("USER_ID") %></td>
                            <td><%# Eval("EMPLOYEE_NUMBER")%></td>
                            <td><%# Eval("USER_NAME")%></td>
                            <td><%# Eval("REAL_NAME")%></td>
                            <td>
                                <asp:LinkButton ID="btnDelete" CommandName="DELETE" CommandArgument='<%#Eval("USER_ID") %>' runat="server">删除</asp:LinkButton>
                            </td>
                        </tr>
                    </AlternatingItemTemplate>
                    <FooterTemplate>                    
                        </table>
                    </FooterTemplate>
                </asp:Repeater>
            </td>
        </tr>
        <tr>
            <td colspan="4" align="center">
                <asp:Button ID="btnSave" runat="server" Text="保存" OnClick="btnSave_Click" />
                <asp:Button ID="btnBack" runat="server" Text="返回" OnClick="btnBack_Click" />
            </td>
        </tr>
    </table>
    </form>
</body>
</html>
